package org.bridgen.runtime.model;

/**
 * Bridgit is covered by the new BSD License. 
 * You should have received a copy of the new BSD license with Bridgit.
 * 
 * @author Emma Söderberg <emma add cs.lth.se>
 * Copyright (c) 2009
 */

public class Bridge {
	protected Island start;
	protected Island end;
	protected boolean visited;
	protected int tolerance;

	public Bridge(StartIsland start, EndIsland end, int tolerance) {
		this.start = start;
		this.end = end;
		visited = false;
		tolerance = 0;
	}
	
	public void setVisited(boolean value) {
		visited = value;
	}

	public boolean isVisited() {
		return visited;
	}

	public String toString() {
		return start + " >---< " + end;
	}

	public Island getStart() {
		return start;
	}
	public Island getEnd() {
		return end;
	}
	public int getTolerance() {
		return tolerance;
	}
}
